package com.ccn.kotlin_mvvm.app.wiget.banner

import android.view.View
import com.ccn.kotlin_mvvm.R
import com.zhpan.bannerview.BaseBannerAdapter

class WelcomBannerAdapter : BaseBannerAdapter<String, WelcomBannerViewHolder>() {
    override fun createViewHolder(itemView: View, viewType: Int): WelcomBannerViewHolder {
        return WelcomBannerViewHolder(itemView)
    }

    override fun onBind(
        holder: WelcomBannerViewHolder?,
        data: String?,
        position: Int,
        pageSize: Int
    ) {
        holder?.bindData(data, position, pageSize)
    }

    override fun getLayoutId(viewType: Int): Int {
        return R.layout.banner_itemwelcome
    }
}